package com.it.xuehang.exception;

import lombok.Data;
import org.springframework.validation.BindingResult;

@Data
public class ValidationFailedException extends RuntimeException{
    private BindingResult result;

    public ValidationFailedException(BindingResult result) {
        this.result = result;
    }

    public ValidationFailedException(String message, BindingResult result) {
        super(message);
        this.result = result;
    }



    public ValidationFailedException() {
        super();
    }

    public ValidationFailedException(String message) {
        super(message);
    }

    public ValidationFailedException(String message, Throwable cause) {
        super(message, cause);
    }

    public ValidationFailedException(Throwable cause) {
        super(cause);
    }

    protected ValidationFailedException(String message, Throwable cause, boolean enableSuppression, boolean writableStackTrace) {
        super(message, cause, enableSuppression, writableStackTrace);
    }
}
